Dishwashers can include a heater for heating wash liquid for treating dishes according to an automatic cycle of operation. A heater may comprise a resistive heating element and a number of electrical components to couple the resistive heating element to a power supply. For example, a resistive heating element may be selectively coupled to the power supply by electromechanical relays.